﻿<Window x:Class="DiasPlanejamento.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="MainWindow" Height="700" Width="800"
        Loaded="Window_Loaded">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="*" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="*" />
        </Grid.RowDefinitions>

        <GroupBox Grid.Row="0">
            <GroupBox.Header>
                Gisele Fredes
            </GroupBox.Header>

            <ListView Name="Turmas" ItemsSource="{Binding Path=Horarios}">
                <ListView.View>
                    <GridView>
                        <GridView.ColumnHeaderContainerStyle>
                            <Style TargetType="{x:Type GridViewColumnHeader}">
                                <Setter Property="IsEnabled" Value="False" />
                                <Style.Triggers>
                                    <Trigger Property="IsEnabled" Value="False">
                                        <Setter Property="TextElement.Foreground" Value="Black" />
                                    </Trigger>
                                </Style.Triggers>
                            </Style>
                        </GridView.ColumnHeaderContainerStyle>
                        
                        <!-- Add GridVeiw Columns -->
                        <GridViewColumn Header="Hor" Width="50"  DisplayMemberBinding="{Binding Path=Hor}" />
                        <GridViewColumn Header="Seg" Width="120" DisplayMemberBinding="{Binding Path=Seg}" />
                        <GridViewColumn Header="Ter" Width="120" DisplayMemberBinding="{Binding Path=Ter}" />
                        <GridViewColumn Header="Qua" Width="120" DisplayMemberBinding="{Binding Path=Qua}" />
                        <GridViewColumn Header="Qui" Width="120" DisplayMemberBinding="{Binding Path=Qui}" />
                        <GridViewColumn Header="Sex" Width="120" DisplayMemberBinding="{Binding Path=Sex}" />

                    </GridView>
                </ListView.View>
            </ListView>
        </GroupBox>


        <GroupBox Grid.Row="1">
            <GroupBox.Header>
                Período
            </GroupBox.Header>

            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="*" />
                    <ColumnDefinition Width="Auto" />
                    <ColumnDefinition Width="*" />
                </Grid.ColumnDefinitions>

                <TextBox Grid.Column="0" HorizontalAlignment="Right" Width="150"
                         Text="{Binding Path=InicioPeriodo, StringFormat=d}" />
                <TextBlock Grid.Column="1" Text="a" Margin="10,0" />
                <TextBox Grid.Column="2" HorizontalAlignment="Left" Width="150"
                         Text="{Binding Path=FimPeriodo, StringFormat=d}" />

            </Grid>
        </GroupBox>

        <GroupBox Grid.Row="2">
            <GroupBox.Header>
                Turmas
            </GroupBox.Header>

            <UniformGrid Rows="1" Columns="6">
                <UniformGrid.Resources>
                    <Style TargetType="Button">
                        <Setter Property="Margin" Value="10" />
                        <EventSetter Event="Click" Handler="Button_Click"/>
                    </Style>
                </UniformGrid.Resources>
                <Button Content="Turma 61" Tag="61"/>
                <Button Content="Turma 62" Tag="62"/>
                <Button Content="Turma 71" Tag="71"/>
                <Button Content="Turma 72" Tag="72"/>
                <Button Content="Turma 81" Tag="81"/>
                <Button Content="Turma 82" Tag="82"/>
            </UniformGrid>
        </GroupBox>

        <GroupBox Grid.Row="3">
            <GroupBox.Header>
                Datas
            </GroupBox.Header>
            <RichTextBox x:Name="Saida" />
        </GroupBox>

    </Grid>
</Window>